package JVM;

import java.util.Arrays;

/**
 * @author:谢君臣
 * @Date:2021/9/23-19:33
 * @version:1.0
 * @function:
 */
public class Test {
    public static void main(String[] args) {
        Integer c=1;
        /**
         *  0 iconst_1              取值-1~5采用iconst指令将常量压入栈中
         *  1 invokestatic #2       属于静态绑定 Integer.valueOf(1)
         *  4 astore_1              存储在局部变量1号位置
         */
        Integer h=6;
        /**
         *  5 bipush 6              取值-128~127采用bipush指令将常量压入栈中
         *  7 invokestatic #2
         *  10 astore_2
         */
        Long e=128L;
        Long f=128L;
        System.out.println(c==h);//true
        System.out.println(e==f);//false


        String temp = "152";
        System.out.println(temp.contains("5"));
        int [] arr = new int[10];
        int[] ints = Arrays.copyOfRange(arr, 0, 2);

        //demo(200);
    }
    static void demo(int i){
        Integer num1 = new Integer(i);
        Integer num2 = new Integer(i);
        Integer num3 = i;
        Integer num4 = Integer.valueOf(i);
        Integer num5 = Integer.valueOf(i);
        System.out.print(num1==num2);
        System.out.print(",");
        System.out.print(num2==num3);
        System.out.print(",");
        System.out.print(num3==num4);
        System.out.print(",");
        System.out.print(num4==num5);


    }
}
